package com.google.appengine.a4ieve.servlets.resources;

import com.google.appengine.a4ieve.StudentGroup;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.io.IOException;
import java.util.logging.Logger;

/**
 * User: lunin
 * Date: 4/24/14
 * Time: 10:45 AM
 */
public class GetGroupsServant implements Servant {

    private static final Logger LOG = Logger.getLogger(GetAchievementTypeServant.class.getName());

    @Override
    public void process(HttpServletRequest req, HttpServletResponse resp) {
        try {
            StudentGroup.getRepresentation().write(resp.getWriter());
        } catch (IOException e) {
            LOG.severe("Error writing achievement class" + e);
        }
    }
}
